package cn.jbolt.ai.klb.dao;

import cn.jbolt.util.Result;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import cn.jbolt.ai.klb.entity.AiDoc;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Mapper
public interface AiDocMapper extends BaseMapper<AiDoc> {

    List<AiDoc> getList(@Param("page") Integer page, @Param("pageSize") Integer pageSize, @Param("keywords") String keywords,
                        @Param("aiKnowledgeBaseId") Long aiKnowledgeBaseId, @Param("dataType") String dataType, @Param("status") Integer status);

    long getListCount( @Param("keywords") String keywords,
                       @Param("aiKnowledgeBaseId") Long aiKnowledgeBaseId, @Param("dataType") String dataType, @Param("status") Integer status);

    List<AiDoc> getDocListByIds(@Param("ids")  List<String>  ids);

    AiDoc getDocById(@Param("id") Long id);

    List<AiDoc> getQADocListByFileId(@Param("fileId") Long fileId);
}

